import random


def stone_scissors_paper():
    your_score = 0
    computer_score = 0
    for i in range(3):
        yours = input("你出的是：")
        computer = random.choice(['石头', '剪刀', '布'])
        print("电脑出的是：", computer)
        if yours == computer:
            your_score += 1
            computer_score += 1
        elif (yours == '石头' and computer == '剪刀') or (yours == '剪刀' and computer == '布') or (
                yours == '布' and computer == '石头'):
            your_score += 1
        else:
            computer_score += 1
        print("你得%d分，电脑得%d分" % (your_score, computer_score))
    if your_score == computer_score:
        print("平局")
    elif your_score > computer_score:
        print("你赢了")
    else:
        print("你输了")


